home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Software of the Month Club 1996 June
/
Software of the Month Club 1996 June.iso
/
pc
/
win
/
sri
/
raytrace
/
qcktour6.rsc
< prev
next >
Wrap
Text File
|
1995-09-07
|
4KB
|
186 lines
.run_from qcktour5.rsc
.file_new
.control_key_up
.new_text
This example will demonstrate ray paths through a rectangular
refracting slab.
Click on Yes to see this example, click on No to skip to the next example.
.yes_no OK SKIP
:OK
.create_element
.fast_click 400 200
.fast_click 150 200
.fast_click 150 120
.fast_click 400 120
.region
.set_length 120
.create_ray
.fast_click 190 280
.fast_click 280 175
.finish
.pause 500
.new_text
The ray paths can be controlled at every boundary by setting the "fertility"
of the rays. This is done by selecting the ray and using the Modify -- Ray menu item.
Press the space bar to see a normal and reflected ray generated at the top surface
of the slab.
.pause
.move 210 258
.pause 400
.click 210 258
.pause 400
.reflect
.pause 300
.normal
.new_text
The ray can also be projected across the slab.
Press the space bar to see a forward projected ray.
.pause
.forward_project
.new_text
You might also be interested in the reflection of the lower surface of the
slab.
Press the space bar to see this.
.pause
.move 282 152
.pause 400
.click 282 152
.pause 400
.reflect
.pause 1000
.new_text
Now that the basic ray diagram is set up, various parts can be dragged about.
For example the thickness of the slab can be changed.
Press the space bar to see this.
.pause
.new_text
The slab must be selected by clicking somewhere on its outline.
.pause 500
.move 400 150
.pause 1000
.click 400 150
.pause 1000
.new_text
To drag an edge the control key is held down while clicking on the edge.
Press the space bar to continue.
.pause
.control_key_down
.move 250 120
.pause 500
.click 250 120
.control_key_up
.pause 500
.new_text
Now the cursor is in the drag form the edge can be moved about.
Press the space bar to continue.
.pause
.move 250 80
.pause 500
.move 250 120
.pause 500
.new_text
Try moving the cursor now to drag the edge.
Notice how the displacement of the transmitted ray varies with
the thickness of the slab.
Click on the primary mouse button to return to the script.
.mouse_limits 240 70 260 220
.allow_drag
.click 250 120
.new_text
Or you could change the slab so that the top and bottom were not parallel by dragging
one of the vertices.
Press the space bar to see this.
.pause
.move 400 120
.pause 500
.click 400 120
.pause 500
.move 400 100
.new_text
Try moving the cursor now to drag the vertex.
Click on the primary mouse button to return to the script.
.mouse_limits 390 80 410 180
.allow_drag
.click 400 120
.new_text
A protractor can be used to measure the angle of incidence and
a tape measure can be used to measure the lateral displacement
of the transmitted ray.
Press the space bar to continue.
.pause
.quiet_snap
.create_protractor
.end_snap
.fast_click 208 259
.end_snap
.fast_click 258 260
.mid_snap
.fast_click 208 259
.new_text
.fast_click 241 220
.protractor_options 0 leader degrees
.fast_click 270 211
.fast_click 116 217
.create_tapemeasure
.mid_snap
.fast_click 324 87
.perp_snap
.fast_click 349 95
.fast_click 346 83
.tapemeasure_options 1 0 leader distance
.fast_click 354 93
.fast_click 450 90
.fast_click 230 70
.new_text
Press the space bar to gain control of Raytrace and try dragging the slab
or the incident ray about.
.pause
.new_text
Remember:
Select an object by clicking on its outline.
Drag the selected object by clicking on it again.
Use the control key when clicking to drag an edge.
Click on the Continue button to return to the script.
.user_control
.new_text
That's the end of this example. A similar ray diagram is available
in the file SLAB.RAY which you can load and modify later.
Press the space bar to go to the next example.
.pause
:SKIP
.script qcktour7.rsc